-
-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
🐛 Fix Elastica\Document undefined method #1476
Conversation
Elasticsearch types have been deprecated in v6.x and removed from v7.x. The proper way to upgrade to the new ES is to completely remove the This would be a BC break; do not forget to fix the dependency to the right version of the |
any news on this |
same here |
Anybody would support me to have a testing environment up and running to fix this? I can save some time next week to work on this issue |
@@ -72,7 +72,7 @@ protected function getDocument(array $record): Document | |||
{ | |||
$document = new Document(); | |||
$document->setData($record); | |||
$document->setType($this->type); | |||
$document->setOpType($this->type); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The opType
is the operation type and not at all the same as types
in ES<7. See https://github.com/ruflin/Elastica/blob/b1b6c980cce2ffc3f278e0d3d02e61b174cee52e/src/AbstractUpdateAction.php#L186
Fixed by #1523 |
Fix undefined method call to
Elastic\Document::setType()
in ElasticaFormatter Class.